" 显示行号
set nu
" TAB键所跳格数
set	tabstop=4 
" 代码自动补全
" ctrl+P
set tags+=/usr/src/linux-headers-2.6.32-33-generic/include/tags
"set path+=/usr/src/linux-headers-2.6.32-33-generic/include
set tags+=/usr/include/tags
set tags+=~/.vim/tags/cpp
set tags+=~/.vim/tags/gtkmm
set tags+=~/.vim/tags/all_cpp
" 自动缩进
set autoindent
set cindent
set softtabstop=4
set shiftwidth=4

" 设置omni
set nocp
filetype plugin on

map <C-F12> :!ctags -R --c++-kinds=+p --fields=+iaS --extra=+q .<CR>
nmap <silent> <leader>uc :!ctags -R --c++-kinds=+p --fields=+iaS --extra=+q .<CR>

let OmniCpp_NamespaceSearch = 1
let OmniCpp_GlobalScopeSearch = 1
let OmniCpp_ShowAccess = 1
let OmniCpp_ShowPrototypeInAbbr = 1 " show function parameters
let OmniCpp_MayCompleteDot = 1 " autocomplete after .
let OmniCpp_MayCompleteArrow = 1 " autocomplete after ->
let OmniCpp_MayCompleteScope = 1 " autocomplete after ::
let OmniCpp_DefaultNamespaces = ["std", "_GLIBCXX_STD"]
" automatically open and close the popup menu / preview window
au CursorMovedI,InsertLeave * if pumvisible() == 0|silent! pclose|endif
set completeopt=menuone,menu,longest,preview

"""""""""""""""""""""""""""""""""""""""
" 设置Taglist
"""""""""""""""""""""""""""""""""""""""
" 设置ctags的路径
let Tlist_Ctags_Cmd = "/usr/bin/ctags"
" 不同时显示多个文件的tag
let Tlist_Show_One_File = 1
" 如果taglist是最后一个窗口就退出
let Tlist_Exit_OnlyWindow = 1
" 让当前不被编辑的文件列表自动叠起来
let Tlist_File_Fold_Auto_Close = 1
" 自动打开
" let Tlist_Auto_Open = 1
" 把taglist置于右侧
let Tlist_Use_Right_Window = 1
" 显示菜单
let Tlist_Show_Menu = 1

"""""""""""""""""""""""""""""""""""""""
" winManager 设置
"""""""""""""""""""""""""""""""""""""""
" 设置界面分割
let g:winManagerWindowLayout = "TagList|FileExplorer,BufExplorer"
" 设置winManager宽度
let g:winManagerWidth = 30
" 定义打开键
nmap <silent> <F8> :WMToggle<cr>






